

public class 普通类 {
    static class MyArray {
        public Object[] array= new Object[10];

        public Object getPos(int pos){
            return this.array[pos];
        }

        public void setVal(int pos, Object val) {
            this.array[pos]=val;
        }
    }

    public static void main(String[] args) {
        MyArray myArray= new MyArray();
        myArray.setVal(0, 10);
        myArray.setVal(1, "hello");

        String ret = (String)myArray.getPos(1);
        System.out.println(ret);
    }
}
